package com.zkingsoft.model;

import java.io.Serializable;
import java.util.Date;

import org.springframework.format.annotation.DateTimeFormat;

import com.zkingsoft.plugin.util.DateUtils;

/**
 * 
 * @Description: 用户对象
 * @author:姜友瑶
 * @date 2016年8月31日
 */
public class Users implements Serializable {

	private static final long serialVersionUID = 1L;

	private Long id;

	/**
	 * 真实姓名
	 */
	private String name;

	/**
	 * 电话号码
	 */
	private String tel;

	/**
	 * 住址
	 */
	private String address;

	/**
	 * 头像
	 */
	private String photo;

	/**
	 * 性别
	 */
	private String sex;

	/**
	 * 角色
	 */
	private Long roleId;

	/**
	 * 邮箱
	 */
	private String email;

	/**
	 * 账号
	 */
	private String account;

	/**
	 * 密码
	 */
	private String password;

	/**
	 * 注册时间
	 */
	private Date registerTime;

	/**
	 * qqid
	 */
	private String qqId;

	/**
	 * 微信id
	 */
	private String weixinId;

	/**
	 * 等级
	 */
	private String grade;

	/**
	 * 推荐人
	 */
	private Long parentUserId;

	/**
	 * 部门
	 */
	private Long deptId;

	/**
	 * 是否删除 N 未删除，Y已删除
	 */
	private String isDeleted;

	/**
	 * 用户类型
	 */
	private String userType;

	/**
	 * 微博id
	 */
	private String weiboId;

	/**
	 * 身份证
	 */
	private String idcard;

	/**
	 * 年龄
	 */
	private Integer age;

	/**
	 * 职称
	 */
	private String jobTitle;

	/**
	 * 别名，昵称
	 */
	private String aliases;

	/**
	 * 工作编号
	 */
	private String jobNo;

	/**
	 * 公司id
	 */
	private Long companyId;

	/**
	 * 备用电话号码
	 */
	private String tel2;

	/**
	 * 账户状态
	 */
	private String accountStatus;

	/**
	 * 激活码
	 */
	private String validateCode;

	/**
	 * 激活最后时间
	 */
	private Date validateEndTime;
	/**
	 * 生日
	 */
	@DateTimeFormat(pattern=DateUtils.DATE_FORMAT_DD)
	private Date birthday;

	/**
	 * 扩展属性
	 * 
	 * @return
	 */
	private Company company;

	private Role role;

	public Role getRole() {
		return role;
	}

	public void setRole(Role role) {
		this.role = role;
	}

	public Company getCompany() {
		return company;
	}

	
	public Date getBirthday() {
		return birthday;
	}

	public void setBirthday(Date birthday) {
		this.birthday = birthday;
	}

	public void setCompany(Company company) {
		this.company = company;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getTel() {
		return tel;
	}

	public void setTel(String tel) {
		this.tel = tel;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getPhoto() {
		return photo;
	}

	public void setPhoto(String photo) {
		this.photo = photo;
	}

	public String getSex() {
		return sex;
	}

	public void setSex(String sex) {
		this.sex = sex;
	}

	public Long getRoleId() {
		return roleId;
	}

	public void setRoleId(Long roleId) {
		this.roleId = roleId;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getAccount() {
		return account;
	}

	public void setAccount(String account) {
		this.account = account;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public Date getRegisterTime() {
		return registerTime;
	}

	public void setRegisterTime(Date registerTime) {
		this.registerTime = registerTime;
	}

	public String getQqId() {
		return qqId;
	}

	public void setQqId(String qqId) {
		this.qqId = qqId;
	}

	public String getWeixinId() {
		return weixinId;
	}

	public void setWeixinId(String weixinId) {
		this.weixinId = weixinId;
	}

	public String getGrade() {
		return grade;
	}

	public void setGrade(String grade) {
		this.grade = grade;
	}

	public Long getParentUserId() {
		return parentUserId;
	}

	public void setParentUserId(Long parentUserId) {
		this.parentUserId = parentUserId;
	}

	public Long getDeptId() {
		return deptId;
	}

	public void setDeptId(Long deptId) {
		this.deptId = deptId;
	}

	public String getIsDeleted() {
		return isDeleted;
	}

	public void setIsDeleted(String isDeleted) {
		this.isDeleted = isDeleted;
	}

	public String getUserType() {
		return userType;
	}

	public void setUserType(String userType) {
		this.userType = userType;
	}

	public String getWeiboId() {
		return weiboId;
	}

	public void setWeiboId(String weiboId) {
		this.weiboId = weiboId;
	}

	public String getIdcard() {
		return idcard;
	}

	public void setIdcard(String idcard) {
		this.idcard = idcard;
	}

	public Integer getAge() {
		return age;
	}

	public void setAge(Integer age) {
		this.age = age;
	}

	public String getJobTitle() {
		return jobTitle;
	}

	public void setJobTitle(String jobTitle) {
		this.jobTitle = jobTitle;
	}

	public String getAliases() {
		return aliases;
	}

	public void setAliases(String aliases) {
		this.aliases = aliases;
	}

	public String getJobNo() {
		return jobNo;
	}

	public void setJobNo(String jobNo) {
		this.jobNo = jobNo;
	}

	public Long getCompanyId() {
		return companyId;
	}

	public void setCompanyId(Long companyId) {
		this.companyId = companyId;
	}

	public String getTel2() {
		return tel2;
	}

	public void setTel2(String tel2) {
		this.tel2 = tel2;
	}

	public String getAccountStatus() {
		return accountStatus;
	}

	public void setAccountStatus(String accountStatus) {
		this.accountStatus = accountStatus;
	}

	public String getValidateCode() {
		return validateCode;
	}

	public void setValidateCode(String validateCode) {
		this.validateCode = validateCode;
	}

	public Date getValidateEndTime() {
		return validateEndTime;
	}

	public void setValidateEndTime(Date validateEndTime) {
		this.validateEndTime = validateEndTime;
	}

	@Override
	public String toString() {
		return "Users [id=" + id + ", name=" + name + ", tel=" + tel + ", address=" + address + ", photo=" + photo
				+ ", sex=" + sex + ", roleId=" + roleId + ", email=" + email + ", account=" + account + "： registerTime=" + registerTime + ", qqId=" + qqId + ", weixinId=" + weixinId + ", grade="
				+ grade + ", parentUserId=" + parentUserId + ", deptId=" + deptId + ", isDeleted=" + isDeleted
				+ ", userType=" + userType + ", weiboId=" + weiboId + ", idcard=" + idcard + ", age=" + age
				+ ", jobTitle=" + jobTitle + ", aliases=" + aliases + ", jobNo=" + jobNo + ", companyId=" + companyId
				+ ", tel2=" + tel2 + ", accountStatus=" + accountStatus + ", validateCode=" + validateCode
				+ ", validateEndTime=" + validateEndTime + ", birthday=" + birthday + ", company=" + company + ", role="
				+ role + "]";
	}

	

}